Problem

Find the measurement covariance matrix, $R$, for the optical flow sensor.

Model

$ \dot{x} = f(x, u)$

$ y = h(x) $

Estimate

$ \dot{\hat{x}} = f(\hat{x}, u)$

$ \hat{y} = h(\hat{x}) $

Innovation:

$ r = y - \hat{y} $

$ S = E[rr^T] = HPH^T + R $

Numerical Estimation

$S = cov(r)$ - can compute using a finite sample equation

Solve for R

$R = S - HPH^T$